package top.tangyh.lamp.care.service;

import top.tangyh.basic.base.service.SuperService;
import top.tangyh.lamp.care.entity.BIoRecord;
import top.tangyh.lamp.care.vo.query.DataForIoVOQuery;
import top.tangyh.lamp.care.vo.query.IoItemQueryParam;
import top.tangyh.lamp.care.vo.query.SelectStatisticParam;
import top.tangyh.lamp.care.vo.result.*;
import top.tangyh.lamp.care.vo.save.BIoRecordSaveVO;
import top.tangyh.lamp.care.vo.save.IoRecordInVO;
import top.tangyh.lamp.care.vo.save.IoSuspensionFrameDataInVo;
import top.tangyh.lamp.care.vo.update.BIoRecordUpdateVO;
import top.tangyh.lamp.care.vo.query.BIoRecordPageQuery;

import java.util.List;
import java.util.Map;


/**
 * <p>
 * 业务接口
 * 出入量记录表
 * </p>
 *
 * @author zqb
 * @date 2024-07-23 10:12:06
 * @create [2024-07-23 10:12:06] [zqb] [代码生成器生成]
 */
public interface BIoRecordService extends SuperService<Long, BIoRecord> {

    /**
     * 出入量 添加/修改值
     */
    Long  addOrUpdateYxIoRecord(IoRecordInVO yxIoRecordPO);

    Map addOrUpdateYxIoRecordBatch(List<IoRecordInVO> yxIoRecordPOs);

    /**
     *  出入量 集合查询
     * @param statisticParam
     * @return
     */
    Map<String, Map<String, List<IoRecordVO>>>  listOfIoRecord(SelectStatisticParam statisticParam);

    /**
     * 获取出入量选项
     * @param ioItemQueryParam
     * @return
     */
    List<IoItemVO> itemQuery(IoItemQueryParam ioItemQueryParam);


    /**
     * 查询出量和入量指定时间的统计
     * @param hospitalNumber
     * @param startTime
     * @param endTime
     * @return
     */
    SumOfIoStatisticslVO selectSumStatistic(String hospitalNumber, String startTime, String endTime);

    /**
     * 根据时间 删除对应数据
     * @param time
     * @return
     */
    int deleteByTime(String time);

    /**
     * 出入量悬浮框数据
     * @param queryVO
     * @return
     */
    List<IoSuspensionFrameData> selectIoSuspensionFrameData(IoSuspensionFrameDataInVo queryVO);


    /**
     * 出入量弹框列表数据查询
     * @param queryVO
     * @return
     */
    List<DataForIoOUtVO> selectDialogList(DataForIoVOQuery queryVO);


    /**
     * @Description:  尿量统计
     * @Param:
     * @return:
     * @Author: Mr.zqb
     * @Date: 2022/2/23
     */
    List<TemperateIODataVO> selectSumOfNlList(String hospitalNumber,String itemCode,String startTime,String endTime);

    /**
     *  引流量统计
     * @param hospitalNumber
     * @param startTime
     * @param endTime
     * @return
     */
    List<TemperateIODataVO>  selectSumOfLiuLiangList(String hospitalNumber,String startTime,String endTime);

    /**
     *  出入量统计
     * @param hospitalNumber
     * @param startTime
     * @param endTime
     * @return
     */
    List<TemperateIODataVO> selectSumOfOutInList(String hospitalNumber,String startTime,String endTime);


    void saveList(List<IoRecordInVO> io, Long time, String operator, String account, String patientIdent,String hospitalNumber);

}


